package com.stoa.floatlib.config

import com.stoa.floatlib.constant.SharePrefsKey
import com.stoa.floatlib.utils.SpUtils

object FloatIconConfig {
    fun getLastPosX(viewTag: String): Int {
        return SpUtils.getInt(SharePrefsKey.FLOAT_ICON_POS_X + viewTag, 0)
    }

    fun getLastPosY(viewTag: String): Int {
        return SpUtils.getInt(SharePrefsKey.FLOAT_ICON_POS_Y + viewTag, 0)
    }

    fun saveLastPosX(viewTag: String, value: Int) {
        SpUtils.putInt(SharePrefsKey.FLOAT_ICON_POS_X + viewTag, value)
    }

    fun saveLastPosY(viewTag: String, value: Int) {
        SpUtils.putInt(SharePrefsKey.FLOAT_ICON_POS_Y + viewTag, value)
    }
}